package net.zjitc.tree;

public class TreeNode<T> {
    T data;  //本身数据
    TreeNode left; //左孩子
    TreeNode rigth; //右孩子

    public TreeNode() {
    }

    public TreeNode(T data) {
        this.data = data;
    }

    public TreeNode(TreeNode left, T data) {
        this.data = data;
        this.left = left;
    }

    public TreeNode(T data, TreeNode rigth) {
        this.data = data;
        this.rigth = rigth;
    }

    public TreeNode(T data, TreeNode left, TreeNode rigth) {
        this.data = data;
        this.left = left;
        this.rigth = rigth;
    }

}
